<!DOCTYPE html>
<!--
Copyright 2013 Mozilla Foundation

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<html>
  <head>
    <meta charset="utf-8">
    <title>Shumway Inspector</title>
    <link rel="stylesheet" href="style/font-awesome.css">
    <link rel="stylesheet" href="style/controls.css">
    <link rel="stylesheet" href="style/style.css">
    <script src="../../src/compatibility.js"></script>
  </head>
  <body>
    <div id="topToolbar" class="toolbarBox withEmphasis">
      <div class="toolbarLabel"><span id="message" class="toolbarMessage"></span></div>
      <div id="debugInfoToolbarTabs" class="toolbarButtonBar active">
        <div id="showScratchCanvases" class="toolbarButton" data-panelid="scratchCanvasContainer">Scratch Canvases</div>
        <div id="showAsset" class="toolbarButton" data-panelid="assetListContainer">Assets</div>
        <div id="showDebugInfo" class="toolbarButton" data-panelid="debugInfoContainer">Debug Info</div>
        <div id="showDisplayList" class="toolbarButton" data-panelid="displayListContainer">Frame Tree</div>
        <div id="showSettings" class="toolbarButton pressedState" data-panelid="settingsContainer">Settings</div>
        <div id="showNothing" class="toolbarButton" data-panelid="none">×</div>
      </div>
      <div id="openFile" class="toolbarButton" title="Select SWF/ABC file (or drag'n'drop the file on the stage).">Open File</div>
    </div>

    <iframe id="gfxIframe" src="inspector.gfx.html" tabindex="1"></iframe>
    <iframe id="playerIframe" src="inspector.player.html"></iframe>

    <div id="panelContainer">
      <div id="scratchCanvasContainer" tabindex='1'>

      </div>
      <div id="assetListContainer">
        <ul id="assetList"></ul>
      </div>
      <div id="debugInfoContainer">
        <canvas id="traceTerminal" tabindex='2' title="terminal window&#xa;(h - print help)"></canvas>
      </div>
      <div id="displayListContainer">
        <div class="toolbarBox">
          <div class="toolbarLabel"></div>
          <div id="displayListButtons">
            <div id="viewDisplayList" class="toolbarButton">Live View</div>
          </div>
        </div>
        <div id="displayList" style="margin-top: 32px;">
        </div>
      </div>
      <div id="settingsContainer" class="active">
      </div>
    </div>
    <div id="profilerContainer" class="collapsed">
      <div id="profilerToolbar" class="toolbarBox">
        <div class="toolbarLabel">Shumway Profiler <span id="profilerMessage" class="toolbarMessage">6 Seconds</span></div>
        <div id="profilerMinimizeButton" class="toolbarIconButton icon-generic"></div>
        <div id="profilerButtons">
          <div class="toolbarButtonBar active">
            <div id="profilerImport" class="toolbarButton">Import</div>
            <div id="profilerExport" class="toolbarButton">Export</div>
          </div>
          <div id="profilerStartStop" class="toolbarButton">Start</div>
        </div>
      </div>
      <div id="profiler">
        <div id="profileList">
        </div>
        <div id="profilePanel">
        </div>
      </div>
    </div>
    <script>
      var initStartTime = Date.now();
    </script>

    <script> console.time("Load Shared Dependencies"); </script>

    <script src="../../build/version/version.js"></script>
    <script src="../../build/ts/base.js"></script>
    <script src="../../build/ts/tools.js"></script>
    <script src="../../build/ts/gfx-base.js"></script>

    <script> console.timeEnd("Load Shared Dependencies"); </script>

    <input type="file" id="files" name="files[]" multiple style="visibility: hidden;" accept="application/x-shockwave-flash">

    <script src="js/classes/DisplayListTree.js"></script>
    <script src="js/classes/SWFController.js"></script>
    <script src="js/classes/classList.min.js"></script>
    <script src="js/classes/dat.gui.js"></script>
    <script src="debug/pingpong.js"></script>

    <script src="js/inspectorProfiler.js"></script>
    <script src="js/inspectorSettings.js"></script>
    <script src="js/inspectorLoader.js"></script>
    <script src="js/inspectorDisplayList.js"></script>
    <script src="js/inspectorMocks.js"></script>
    <script src="js/remoteDebugging.js"></script>
    <script src="js/inspector.js"></script>
  </body>
</html>
